#!/usr/bin/env python
#coding:utf-8

import pygtk
pygtk.require('2.0')
import gtk
import gtk.glade

class MyWindow:
    def __init__(self):
        self.wTree = gtk.glade.XML('my1.glade')
        #self.window = self.wTree.get_widget('MainWindow')
        dic = {'OnQuit'  :  self.OnQuit,
                  'OnAbout' :  self.OnAbout,
               'OnMainWindowDestroy' : gtk.main_quit}
                  
        self.wTree.signal_autoconnect(dic)
        #self.window.connect('destroy', lambda q:gtk.main_quit())

        #window.show()

    def OnQuit(self, widget):
        pass

    def OnAbout(self, widget):
        pass

    def main(self):
        gtk.main()

if __name__ == '__main__':
    window = MyWindow()
    window.main()
